﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections.ObjectModel;
using System.ComponentModel;

namespace WasaWasa
{
    class TimelineBundle : IBundle
    {
        public TimelineType Type { get; set; }

        private int selectedIndex;
        public int SelectedIndex
        {
            get { return selectedIndex; }
            set
            {
                selectedIndex = value;
                SelectedItem.IsReaded = true;
            }
        }
        public StatusClass SelectedItem
        {
            get { return Timeline[SelectedIndex]; }
        }
        public string Name { get; set; }
        public string ApiPath { get; set; }
        public string ApiParam { get; set; }
        public ObservableCollection<StatusClass> Timeline { get; private set; }
        public int RemainedTime { get; set; }
        public DateTime lastModified { get; set; }
        public Dictionary<string, object> Tags { get; set; }

        public bool IsLoaded { get; set; }
        public DateTime LastLoaded { get; set; }
        public int LastLoadedCount { get; set; }

        public TimelineBundle()
        {
            Timeline = new ObservableCollection<StatusClass>();
            Tags = new Dictionary<string, object>();
        }
    }

    public enum TimelineType
    {
        Other,
        Friends,
        Recent,
        Reply,
        Public,
        SL,
        Channel,
        User,
    }
}
